<?php
$url["lang"] = $_GET["lang"];
$url["email"] = $_GET["email"];
$email=$_GET["email"];



if (preg_match("/^[_a-z0-9-]+(\.[_a-z0-9+-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,})$/i", $email)){
	$link = "login.php?".http_build_query($url)." ";
	echo '<script> window.location="'.$link.'"; </script> ';
}else{
	$link = "index.php?flag=1";
	echo '<script> window.location="'.$link.'"; </script> ';
}

?>